//
//  networkTrafficController.m
//  exampleProject
//
//  Created by Jones, Alex on 01/08/2011.
//  Copyright 2011 __MyCompanyName__. All rights reserved.
//

#import "networkTrafficController.h"

@implementation networkTrafficController
@synthesize delegate;

- (id)init {
    self = [super init];
    if (self) {
        
    }
    return self;
}
-(void)initWithRequestForJSON:(NSString *) path
{
    
   
    NSURL *url = [NSURL URLWithString:@"http://www.rowenaoven.co.uk/main.json"];
    
    NSData *jsonData = [NSData dataWithContentsOfURL:url];
    
    NSError *error;
    id json = [NSJSONSerialization JSONObjectWithData:jsonData options:NSJSONReadingMutableLeaves error:&error];
    
    [self.delegate recieveJSON:json];
}

@end
